package com.grep.base.util;

import java.io.IOException;
import java.io.InputStream;
import java.util.Properties;


public class PropertiesUtil {
	private static  Properties p ;
	
	private static final PropertiesUtil   instance = new PropertiesUtil();
	private PropertiesUtil(){
		load();
	}
	private   void load(){
		InputStream in = PropertiesUtil.class.getResourceAsStream("/config/cralwer_file.properties");
		p = new Properties();
		try {
			p.load(in);
		} catch (IOException e) { 
			e.printStackTrace();
		}
	}
	public static PropertiesUtil getInstance(){
		return instance;
	}
	public  String geRootPath(){
		return p.getProperty("filePath");
	}
	 public static void main(String args[]){
	 
		 System.out.println(  PropertiesUtil.getInstance().geRootPath());
	 }
	 
}
